1. Field of the Invention
The present invention relates to communication systems, and more particularly, to a method and apparatus for selectively controlling the flow of data between plural network stations.
2. Description of the Related Art
Modem communication systems, such as computer networking systems or communication networks, provide constant transmission of data between end stations and/or intermediate stations such as routers and signal amplifiers. Computer networking systems, such as packet switched networks (e.g., Ethernet networks), often require transmission of data to a single end station or to multiple end stations within the network. The data originates from a user program, and is segmented into multiple data frames and subsequently transmitted in order to simplify processing and minimize the retransmission time required for error recovery. For example, in a conventional e-mail system, a user may desire to send the same e-mail message to four different users that are connected to the e-mail system. Accordingly, the identical data would be directed to multiple end stations.
Packet switched computer networks typically employ a network switch that receives and forwards data frames to individual and/or multiple end stations. The switch makes forwarding decisions upon receipt of data frames based on information contained in a header of each data frame. For example, if a received data frame is to be transmitted to a number of end stations, the switch must make the forwarding decision to forward the data frame to the ports of the correct end stations.
Depending on the specific implementation and/or characteristic of the networking system (i.e., data transfer rate, traffic intensity), buffers must be provided for temporary storage of the data frames received by the switch, until forwarding decisions can be made. Without the use of buffers, there is a great likelihood that data frames will be lost, hence requiring retransmission and reducing the overall efficiency of the system. The buffers used by the switch to store the data frames are often implemented as queue structures. There are many types of electronic data systems in which queues are used. These include microprocessors, memory transfer systems, airline telephone reservation systems, and packet switched networks. An example of a queue from everyday life is a customer line, at a bank or an airport ticket counter.
In most systems, it is desirable that the queues have low latencies so that processing of an entry is not delayed very long due to delays caused by the queues themselves. A low queue latency means that an entry will flow from the entrance to the queue to the exit of the queue quickly, in comparison to queues with higher latencies. One factor that has a significant impact on the latency of a queue is the length, or capacity, of the queue. The greater the capacity of the queue to store entries, the higher the latency of the queue.
During normal operation, however, there is always a possibility that the network will become congested. Network congestion occurs if a receiving network element, for example a receiving network station, is unable to receive data at a rate that is greater than or equal to the transmission rate of the transmitting element. For example, traffic in a client-server environment is dominated by client requests followed by a burst of frames from the server to the requesting client. Hence, only a limited number of client requests can be output to the server from the switched hub at the assigned switching port. If the number of client requests exceeds the capacity of the server""s buffer, some of the data packets will be lost. In another example, a client having limited buffer space may be unable to keep up with the transmission rate of a transmitting station, again resulting in lost packets. Finally, network congestion may occur if a one or more transmitting stations attempt to transmit data packets, via the network switch, to a receiving station that is already in the process of receiving data packets from another transmitting station. Hence, the receiving station may be unable to keep up with reception of data packets from two separate transmitting stations.
Various types of flow control protocols have been proposed to address the problems associated with network congestion. Flow control techniques typically attempt to reduce network congestion by forcing a sending station to temporarily suspend transmission of data packets to another station that is congested. A proposed flow control arrangement for a duplex environment, referred to as IEEE 802.3x[2], specifies generation of a flow control message, for example a PAUSE frame, to regulate the transfer of data and reduce congestion. A transmitting station that receives such a PAUSE frame enters an inactive state in which no frames are sent on the network for a time interval specified in the PAUSE frame.
One problem associated with such flow control proposals, however, is the assumption that flow control should be initiated when a receive buffer is full, which still results in a loss of data. Another problem associated with existing flow control proposals is that the PAUSE frame is often sent to all stations in the network, hence resulting in a significant reduction in network activity every time one station experiences congestion.
Furthermore, the existing proposals do not describe how to determine the instance in which flow control should be initiated. These problems become more complex in a switched environment, where a network switch must route data packets received from a plurality of transmitting stations to the appropriate destination stations. Moreover, if the flow control duration is too short, a receiving station may still lose portions of the transmitted data. If the duration is too long, the transmitting station remains idle, hence reducing network throughput.
There exists a need for an arrangement capable of quickly and efficiently controlling the flow of data between multiple workstations while minimizing the loss of data frames.
There is also a need for an arrangement capable of applying flow control techniques to selected network stations in order to maintain maximum throughput for stations within the network that are not congested.
These and other needs are addressed by the present invention wherein a PAUSE frame is selectively transmitted to a network station in order to temporarily discontinue transmission of data to the congested network station.
In accordance with one aspect of the present invention, a method of regulating the flow of data between plural network stations through a network switch comprises the steps: setting threshold values that indicate a saturation level for internal resources of each transmit port of the switch; receiving, by a receive port of the network switch, a data frame destined to the transmit port, the data frame being received from a first one of the plural network stations; determining if the internal resources of the transmit port have reached the threshold value of that transmit port; and selectively transmitting a PAUSE frame that specifies a pause interval value if the internal resources of that transmit port have reached the threshold values, the PAUSE frame causing the first network station to discontinue transmission of data frames to that transmit port for the duration of the pause interval value. The saturation level corresponds to a level that, if exceeded, can result in a loss of data by a particular port of the network switch. One advantage of the present invention is that the PAUSE frame requires the first network station to discontinue transmission of data frames only to the transmit port whose internal resources have reached the threshold value. This allows a host CPU to efficiently control traffic through the multiport switch by selectively causing transmitting network stations to discontinue transmission to congested ports.
According to another aspect of the invention, an arrangement is provided for regulating the flow of data between plural network stations through a network switch, wherein the plural network stations are connectable to the network switch. The arrangement includes a receive port, a transmit port, a programmable threshold register, and control circuitry. The receive port receives data frames from a first network station, while the transmit port outputs the received data frames to a second network station. The programmable threshold register is used to store a threshold value that indicates a saturation level for the internal resources of the transmit port. The control circuitry monitors the internal resources of the transmit port to determine if the threshold value is reached. If the threshold value has been reached, then the control circuitry transmits a PAUSE frame to the first network station. The PAUSE frame specifies a pause interval value that causes the first network station to discontinue transmission of data frames to the transmit port until the duration of the pause interval value has expired. An important feature of the present invention is the ability to identify congested ports and selectively discontinue transmission of data to the identified ports without affecting other ports of the network switch. Hence, efficient control of traffic through the multiport switch may be achieved.
Additional advantages and novel features of the present invention will be set forth in part in the description which follows, and in part will become apparent to those skilled in the art upon examination of the following, or may be learned by practice of the invention. The advantages of the invention may be realized and attained by means of the instrumentalities and combinations particularly pointed out in the appended claims.